﻿using System;
using System.Collections.Generic;
using System.Text;

namespace xycn.pluginsupport.ControllerPlugins
{
    /// <summary>
    /// 请求模型
    /// </summary>
    public class RequestContext
    {
        /// <summary>
        /// 应用唯一标识 比如 android的IMME号，PC的CpuId 等,用于区分应用唯一标识
        /// </summary>
        public string AppId { get; set; }

        /// <summary>
        /// 应用名称 xlzl
        /// </summary>
        public string AppName { get; set; }

        /// <summary>
        /// 当前页数 针对查询分页接口有效
        /// </summary>
        public int Page { get; set; } = 1;

        /// <summary>
        /// 当前页显示条数 针对查询分页接口有效
        /// </summary>
        public int Limit { get; set; } = 10;

        /// <summary>
        /// 请求来源Ip
        /// </summary>
        public string ReqSrcIp { get; set; }

        /// <summary>
        /// 请求时间轴 unix时间戳 与1970-01-01 0:00:00相差的秒数
        /// </summary>
        public double Timestamp { get; set; }

        /// <summary>
        /// 请求数据对象
        /// </summary>
        public object Data { get; set; }

        /// <summary>
        /// 条件修改数据时有效
        /// </summary>
        public object Where { get; set; }

        /// <summary>
        /// 请求实体Md5 针对Data序列化加密 32位大写md5值 用于确保请求数据一致性
        /// </summary>
        public string Md5 { get; set; }
    }
}
